1. Field of the Invention
The invention disclosed and claimed herein generally pertains to a method for trading or exchanging resources among logical partitions (LPARs) in a data processing system, wherein access to resources such as memory may be non-uniform with respect to latency or access time. More particularly, the invention pertains to a method of the above type wherein resources are traded to improve efficiency in the use of available resources by respective partitions. Even more particularly, the invention pertains to a method of the above type wherein trading and reallocation of resources among respective partitions is guided by a policy directed to improve overall system quality in the use of resources by respective partitions.
2. Description of the Related Art
Increasingly, large symmetric multi-processor data processing systems are not being used as single large data processing systems. Instead, these types of data processing systems are being partitioned and used as smaller systems, also referred to as logical partitioned (LPAR) data processing systems. A logical partitioned functionality within a data processing system allows multiple copies of a single operating system or multiple heterogeneous operating systems to be simultaneously run on a single data processing system platform. A partition, within which an operating system image runs, is assigned a non-overlapping subset of the platforms resources. These resources can be allocated, and may include one or more architecturally distinct processors and their interrupt management areas, regions of system memory, and input/output (I/O) adapter bus slots. The resources of the partition are represented to the operating system image by the platform firmware. Hardware resources in partitioned data processing systems may include, for example, input/output (I/O) adapters, CPUs, non-volatile random access memory (NVRAM), and hard disk drives. Hardware resources can be moved from one partition to another, as needs change.
When a partition is created, several different memory regions may be called upon to provide partition memory. Depending on the hardware, it is possible that each of these memory regions will have different latencies, or access times. Some of these latencies may be comparatively short, where the memory regions are local to the partition. Other memory regions, that are distant from the partition, will have latencies that are excessively long. For some work loads, this can be undesirable. For example, if the central processing unit (CPU) of a partition is assigned memory on the same card as the CPU, the memory is local to the CPU, and the time required for the CPU to access the memory is comparatively short. On the other hand, if the memory is on a different card, the CPU must go through a buffer to access the memory, so that latency will be longer. If the CPU is engaged in activity such as extensive computations, wherein locality between the CPU and memory is important, the quality using the remote memory will be less than the quality using the local memory. On the other hand, if the CPU was only accessing I/O devices, locality may not be important. Moreover, there can be levels of locality or remoteness for a memory region. This is illustrated by considering alternative arrangements, wherein the memory is attached to the CPU cache controller, the memory is not directly attached to the controller but is in the same node as the CPU, or the memory is in the same frame as the CPU but access to the memory must go through one or more buffers.
It has been found that non-uniformity in memory access time, as discussed above, can significantly affect the overall throughput of a partition system. Frequently, discrepancies are noted in the performance of different logical partitions that are running the same workload. For example, a 10% performance difference was observed between two partitions which appeared identically configured, in regard to their respective amounts of memory, CPUs and operating systems. In addition, moving a CPU into a partition can increase the number of remote memory accesses, if the partition is not local with respect to the memory allocations. Similarly, the number of remote accesses could be increased if the CPU was taken from a partition that was local with respect to some or all of the allocated memory.
Notwithstanding undesirable effects such as those described above, which can result from variations in the comparative locality of memory resources, current practice generally requires that once the memory has been allocated to a partition and the partition is running, the partition is expected to make the best use of whatever resources it has received. Very often, this means distributing the memory access across the allocations, which creates an average memory latency value. The average memory latency value depends on the mix of access times and on how much memory each region contributed. As a further example of current practice, during a dynamic reassignment memory could be given away to a more needy partition. In this situation, an arbitrary range of memory is taken from one partition and given to another partition. Locality is not considered in the sense that the request to take or steal memory is a targeted operation against a particular partition. Locality of the memory is not taken into account in this situation.
It is anticipated that overall quality of a partitioned system could be improved, and resources could be used with significantly greater efficiency, if the allocation of resources to respective partitions took into account the comparative importance of resource locality.